package com.easy.query.test.entity.school.proxy;

import com.easy.query.core.expression.parser.core.available.TableAvailable;
import com.easy.query.core.proxy.AbstractProxyEntity;
import com.easy.query.core.proxy.SQLColumn;
import com.easy.query.core.proxy.SQLSelectAsExpression;
import com.easy.query.core.proxy.fetcher.AbstractFetcher;
import com.easy.query.test.entity.school.SchoolStudentAddress;
import com.easy.query.core.proxy.columns.SQLNavigateColumn;

/**
 * this file automatically generated by easy-query, don't modify it
 * 当前文件是easy-query自动生成的请不要随意修改
 *
 * @author xuejiaming
 */
public class SchoolStudentAddressProxy extends AbstractProxyEntity < SchoolStudentAddressProxy, SchoolStudentAddress > {

    private static final Class < SchoolStudentAddress > entityClass = SchoolStudentAddress .class;

    public static SchoolStudentAddressProxy createTable () {
        return new SchoolStudentAddressProxy ();
    }

    public SchoolStudentAddressProxy () {
    }

    /**
     * {@link SchoolStudentAddress#getId}
     */
    public SQLColumn < SchoolStudentAddressProxy, java.lang.String> id(){
    return get("id");
}

    /**
     * {@link SchoolStudentAddress#getStudentId}
     */
    public SQLColumn < SchoolStudentAddressProxy, java.lang.String> studentId(){
    return get("studentId");
}

    /**
     * {@link SchoolStudentAddress#getAddress}
     */
    public SQLColumn < SchoolStudentAddressProxy, java.lang.String> address(){
    return get("address");
}

    /**
     * {@link SchoolStudentAddress#getSchoolStudent}
     */
    public SQLNavigateColumn < SchoolStudentAddressProxy, com.easy.query.test.entity.school.SchoolStudent> schoolStudent(){
    return get("schoolStudent", com.easy.query.test.entity.school.SchoolStudent.class);
}


    @Override
    public Class < SchoolStudentAddress > getEntityClass () {
        return entityClass;
    }


    /**
     * 数据库列的简单获取
     * @return
     */
    public SchoolStudentAddressProxyFetcher FETCHER =
        new SchoolStudentAddressProxyFetcher (this, null, SQLSelectAsExpression.empty);


    public static class SchoolStudentAddressProxyFetcher extends AbstractFetcher<SchoolStudentAddressProxy, SchoolStudentAddress, SchoolStudentAddressProxyFetcher> {

        public SchoolStudentAddressProxyFetcher (SchoolStudentAddressProxy proxy, SchoolStudentAddressProxyFetcher prev, SQLSelectAsExpression sqlSelectAsExpression) {
        super(proxy, prev, sqlSelectAsExpression);
    }


        /**
         * {@link SchoolStudentAddress#getId}
         */
        public SchoolStudentAddressProxyFetcher id() {
            return add(getProxy().id());
        }

        /**
         * {@link SchoolStudentAddress#getStudentId}
         */
        public SchoolStudentAddressProxyFetcher studentId() {
            return add(getProxy().studentId());
        }

        /**
         * {@link SchoolStudentAddress#getAddress}
         */
        public SchoolStudentAddressProxyFetcher address() {
            return add(getProxy().address());
        }


        @Override
        protected SchoolStudentAddressProxyFetcher createFetcher(
            SchoolStudentAddressProxy cp,
            AbstractFetcher<SchoolStudentAddressProxy, SchoolStudentAddress, SchoolStudentAddressProxyFetcher> prev,
            SQLSelectAsExpression sqlSelectExpression
        ) {
            return new SchoolStudentAddressProxyFetcher (cp, this, sqlSelectExpression);
        }
    }

}
